// import { EUIEvent } from "src/Game/MesEvent/EUIEvent";
// import _AllPrefabsNames from "src/Game/_prefabsName/_AllPrefabsNames";
// import RoomManager from "src/GameManager/RoomManager";
// import SceneNode from "src/_T/D3/scene/SceneNode";
// import MesManager from "src/_T/Mes/MesManager";
// import ComResUrl from "src/_T/Res/ComResUrl";
// import { CameraUtils } from "src/_T/Utils/CameraUtils";
// import PlayerBee from "../HoneyBee/EntityHoneyBee/PlayerBee";


// /**雷达地图 控制 */
// export default class MapCameraCon {

//     private constructor() { };
//     private static _Instance: MapCameraCon;
//     public static get Instance(): MapCameraCon {
//         if (this._Instance == null) { this._Instance = new MapCameraCon(); }
//         return this._Instance;
//     }
//     /**跟随玩家的雷达地图 */
//     private FollowMapCamera: Laya.Camera = null;
//     private FollowMapPlan: Laya.Sprite3D = null;
//     /**跟随目标对象 */
//     private FollowTarget: Laya.Sprite3D = null;
//     private MaxTargetImg_With: number = 0;
//     private MaxTargetImg_Hight: number = 0;

//     /**场景固定的雷达地图 */
//     private RoomSceneCamera: Laya.Camera = null;
//     private MaxRoomSceneImg_With: number = 0;
//     private MaxRoomSceneImg_Hight: number = 0;

//     /**场景固定的雷达地图 */
//     private MainSceneCamera: Laya.Camera = null;
//     private MaxSceneImg_With: number = 0;
//     private MaxSceneImg_Hight: number = 0;

//     /**场景固定的雷达地图 */
//     private TempRoomSceneCamera: Laya.Camera = null;
//     private MaxTempSceneImg_With: number = 0;
//     private MaxTempSceneImg_Hight: number = 0;


//     /**跟随雷达的渲染方法 */
//     private FollowRenderFunction: Laya.Handler;
//     /**场景雷达的渲染方法 */
//     private SceneRenderFunction: Laya.Handler;

//     /**玩家雷达 图标 */
//     PlayerMapUI: FGUI_PlayerPoint;
//     /**我方雷达 图标 */
//     BlueBeeMapUI: Map<Laya.Sprite3D, FGUI_GreenPoint> = new Map<Laya.Sprite3D, FGUI_GreenPoint>();
//     /**敌方雷达 图标 */
//     RedBeeMapUI: Map<Laya.Sprite3D, FGUI_RedPoint> = new Map<Laya.Sprite3D, FGUI_RedPoint>();

//     /**玩家雷达 图标 */
//     PlayerSceneMapUI: FGUI_PlayerPoint;
//     /**我方雷达 图标 */
//     BlueSceneBeeMapUI: Map<Laya.Sprite3D, FGUI_GreenPoint> = new Map<Laya.Sprite3D, FGUI_GreenPoint>();
//     /**敌方雷达 图标 */
//     RedBSceneBeeMapUI: Map<Laya.Sprite3D, FGUI_RedPoint> = new Map<Laya.Sprite3D, FGUI_RedPoint>();
//     /**怪物单位 图标 */
//     FiledSceneMapUI: Map<Laya.Sprite3D, any> = new Map<Laya.Sprite3D, any>();

//     /**怪物单位 图标 */
//     FiledFpllowSceneMapUI: Map<Laya.Sprite3D, any> = new Map<Laya.Sprite3D, any>();

//     m_IsPk: boolean = false;

//     /**初始化数据 */
//     public InitMapCamera(level: SceneNode, IsPk: boolean = false) {
//         /**我方雷达 图标 */
//         this.BlueBeeMapUI = new Map<Laya.Sprite3D, FGUI_GreenPoint>();
//         /**敌方雷达 图标 */
//         this.RedBeeMapUI = new Map<Laya.Sprite3D, FGUI_RedPoint>();

//         /**我方雷达 图标 */
//         this.BlueSceneBeeMapUI = new Map<Laya.Sprite3D, FGUI_GreenPoint>();
//         /**敌方雷达 图标 */
//         this.RedBSceneBeeMapUI = new Map<Laya.Sprite3D, FGUI_RedPoint>();
//         /**怪物单位 图标 */
//         this.FiledSceneMapUI = new Map<Laya.Sprite3D, any>();
//         this.FiledFpllowSceneMapUI = new Map<Laya.Sprite3D, any>();
//         let SceneCamearPlan = level.prefabs[_AllPrefabsNames.MianSceneCameraPlan][0];
//         // let RoomCamearPlan = level.prefabs[_AllPrefabsNames.RoomCameraPlan][0];
//         let FollowCamearPlan = level.prefabs[_AllPrefabsNames.FollowMapCameraPlan][0];
//         this.FollowMapPlan = FollowCamearPlan;
//         this.SetFollowMapCamera(FollowCamearPlan.getChildAt(0) as Laya.Camera);
//         this.SetRoomSceneCamera(RoomManager.Instance.GetPlayerRoomData()[0].RoomCamera);
//         console.log(this.RoomSceneCamera);
//         this.SetMainSceneCamera(SceneCamearPlan.getChildAt(0) as Laya.Camera);
//         this.m_IsPk = IsPk;
//         MesManager.on(EUIEvent.ShowMapCameraOpen, this, this.SetMaxMainSceneRender);
//         MesManager.on(EUIEvent.ShowTempMapCameraOpen, this, this.SetTempRoomSceneCamera);
//         this.IsOne = true;
//     }


//     /**设置跟随雷达的摄像机 */
//     public SetFollowMapCamera(TempCamera: Laya.Camera) {
//         this.FollowMapCamera = TempCamera;
//         this.FollowMapCamera.renderingOrder = -2;
//         this.FollowMapCamera.clearFlag = Laya.CameraClearFlags.Sky;
//         this.FollowMapCamera.removeAllLayers();
//         this.FollowMapCamera.addLayer(0);
//     }
//     /**设置场景雷达的摄像机 */
//     public SetRoomSceneCamera(TempCamera: Laya.Camera) {
//         this.RoomSceneCamera = TempCamera;
//         this.RoomSceneCamera.fieldOfView = 75;
//         this.RoomSceneCamera.renderingOrder = -3;
//         this.RoomSceneCamera.clearFlag = Laya.CameraClearFlags.Sky;
//         this.RoomSceneCamera.removeAllLayers();
//         this.RoomSceneCamera.addLayer(0);

//     }
//     /**设置跟随雷达的摄像机 */
//     public SetMainSceneCamera(TempCamera: Laya.Camera) {
//         this.MainSceneCamera = TempCamera;
//         this.MainSceneCamera.fieldOfView = 75;
//         this.MainSceneCamera.renderingOrder = -3;
//         this.MainSceneCamera.clearFlag = Laya.CameraClearFlags.Sky;
//         this.MainSceneCamera.removeAllLayers();
//         this.MainSceneCamera.addLayer(0);
//     }

//     /**设置临时雷达的摄像机 */
//     public SetTempRoomSceneCamera(ClientID: number) {
//         this.TempRoomSceneCamera = RoomManager.Instance.GetPlayerRoomData()[ClientID].RoomCamera;
//         this.TempRoomSceneCamera.renderingOrder = -3;
//         this.TempRoomSceneCamera.clearFlag = Laya.CameraClearFlags.Sky;
//         this.TempRoomSceneCamera.removeAllLayers();
//         this.TempRoomSceneCamera.addLayer(0);
//     }

//     /**设置跟随雷达的方法调用 */
//     public SetFollowRenderFunction() {
//         if (this.m_IsPk) {

//             let T_MapPanel: FightingPanelProxy = FightingPanelProxy.instance;
//             this.FollowMapCamera.renderTarget = new Laya.RenderTexture(T_MapPanel.ui.m_mapBtn.width, T_MapPanel.ui.m_mapBtn.height);
//             let rtex: Laya.Texture = new Laya.Texture(this.FollowMapCamera.renderTarget as any, Laya.Texture.DEF_UV);
//             T_MapPanel.ui.m_mapBtn.displayObject.graphics.drawTexture(rtex);

//         } else {
//             let T_MapPanel: MainProxy = MainProxy.instance;
//             this.FollowMapCamera.renderTarget = new Laya.RenderTexture(T_MapPanel.ui.m_MainMapBtn.width, T_MapPanel.ui.m_MainMapBtn.height);
//             let rtex: Laya.Texture = new Laya.Texture(this.FollowMapCamera.renderTarget as any, Laya.Texture.DEF_UV);
//             T_MapPanel.ui.m_MainMapBtn.displayObject.graphics.drawTexture(rtex);
//         }
//         this.SetFollowMapUI();
//     }

//     rtex: Laya.Texture;
//     /**设置场景雷达的方法调用 */
//     public SetRoomSceneRenderFunction(IsShow: boolean) {
//         let T_MapPanel: MapPanel = MapPanel.instance;
//         if (IsShow) {
//             this.RoomSceneCamera.renderTarget = new Laya.RenderTexture(T_MapPanel.ui.m_MapLoader.width, T_MapPanel.ui.m_MapLoader.height);
//             this.rtex = new Laya.Texture(this.RoomSceneCamera.renderTarget as any, Laya.Texture.DEF_UV);
//             T_MapPanel.ui.m_MapLoader.displayObject.graphics.drawTexture(this.rtex);
//         } else {
//             this.RoomSceneCamera.renderTarget = null;
//         }
//     }

//     /**设置主场景雷达的方法调用 */
//     public SetMainSceneRenderFunction(IsShow: boolean) {
//         let T_MapPanel: MapPanel = MapPanel.instance;
//         if (IsShow) {
//             this.MainSceneCamera.renderTarget = new Laya.RenderTexture(T_MapPanel.ui.m_MapLoader.width, T_MapPanel.ui.m_MapLoader.height);
//             this.rtex = new Laya.Texture(this.MainSceneCamera.renderTarget as any, Laya.Texture.DEF_UV);
//             T_MapPanel.ui.m_MapLoader.displayObject.graphics.drawTexture(this.rtex);

//         } else {
//             this.MainSceneCamera.renderTarget = null;
//         }
//     }

//     /**设置临时雷达的方法调用 */
//     public SetTempRoomSceneRenderFunction(IsShow: boolean) {
//         if (this.TempRoomSceneCamera == null) return;
//         let T_MapPanel: MapPanel = MapPanel.instance;
//         if (IsShow) {
//             this.TempRoomSceneCamera.renderTarget = new Laya.RenderTexture(T_MapPanel.ui.m_MapLoader.width, T_MapPanel.ui.m_MapLoader.height);
//             this.rtex = new Laya.Texture(this.TempRoomSceneCamera.renderTarget as any, Laya.Texture.DEF_UV);
//             T_MapPanel.ui.m_MapLoader.displayObject.graphics.drawTexture(this.rtex);

//         } else {
//             this.TempRoomSceneCamera.renderTarget = null;
//         }
//     }

//     /**设置玩家的层级 */
//     SetPlayerLayer(Layer: Enum_SceneLayer = Enum_SceneLayer.MainScene_Layer) {
//         let PlayBase: PlayerBee = this.FollowTarget.getComponent(PlayerBee);
//         PlayBase.m_SceneLayer = Layer;
//     }

//     Layer: Enum_SceneLayer;
//     /**设置渲染 */
//     SetMaxMainSceneRender() {
//         if (this.FollowTarget == null || this.FollowTarget.destroyed) {
//             return;
//         }
//         let PlayBase: PlayerBee = this.FollowTarget.getComponent(PlayerBee);
//         this.Layer = PlayBase.m_SceneLayer;
//         switch (this.Layer) {
//             case Enum_SceneLayer.Room_Layer:
//                 this.SetRoomSceneRenderFunction(true);
//                 this.SetMainSceneRenderFunction(false);
//                 this.SetTempRoomSceneRenderFunction(false);
//                 break;
//             case Enum_SceneLayer.MainScene_Layer:
//                 this.SetMainSceneRenderFunction(true);
//                 this.SetRoomSceneRenderFunction(false);
//                 this.SetTempRoomSceneRenderFunction(false);
//                 break;
//             case Enum_SceneLayer.Ememy_Layer:
//                 this.SetMainSceneRenderFunction(false);
//                 this.SetRoomSceneRenderFunction(false);
//                 this.SetTempRoomSceneRenderFunction(true);

//         }
//         //if (this.IsOne) {
//         this.SetMainSceneMapUI();
//         // this.IsOne = false;
//         //}
//     }
//     //UIPoint: FGUI_GreenPoint;
//     /**设置跟随雷达的 移动目标 */
//     public SetFollowCameraTarget(Target: Laya.Sprite3D) {
//         this.FollowTarget = Target;
//         this.AddPlayerMapUI();
//     }

//     /**更新摄像机渲染 */
//     public UpdateCameraRender() {
//         if (this.FollowTarget != null && !this.FollowTarget.destroyed) {
//             this.FollowMapPlan.transform.position = new Laya.Vector3(this.FollowTarget.transform.position.x, this.FollowMapPlan.transform.position.y, this.FollowTarget.transform.position.z);
//         }
//         this.CheckIsNull();
//         this.SetImagePos();
//         if (MapPanel.instance.isShow) {
//             this.SetMainSceneMapUIPos();
//         }
//     }

//     IsOne: boolean = true;
//     AddPlayerMapUI() {
//         this.PlayerMapUI = this.CreatorPlayerMapUIInstance(null);
//         this.PlayerSceneMapUI = this.CreatorPlayerMapUIInstance(null);
//         if (this.IsOne) {
//             this.IsOne = false;
//             return;
//         };
//         if (this.m_IsPk) {
//             FightingPanelProxy.instance.ui.m_mapBtn.addChild(this.PlayerMapUI);
//         } else {
//             MainProxy.instance.ui.m_MainMapBtn.addChild(this.PlayerMapUI);
//         }

//     }
//     AddFollowSceneMap(Target: Laya.Sprite3D, Type: EnemyType) {
//         switch (Type) {
//             case EnemyType.Blue_Enemy_Type:
//                 this.AddBlueMapUI(Target, null);
//                 break;
//             case EnemyType.Red_Enemy_Type:
//                 this.AddRedMapUI(Target, null);
//                 break;
//         }
//     }

//     AddMainSceneMap(Target: Laya.Sprite3D, Type: EnemyType) {
//         switch (Type) {
//             case EnemyType.Blue_Enemy_Type:
//                 this.AddMainSceneBlueMapUI(Target, null);
//                 break;
//             case EnemyType.Red_Enemy_Type:
//                 this.AddMainSceneRedMapUI(Target, null);
//                 break;
//         }
//     }
//     /**添加 */
//     AddFiledFollowSceneMap(Target: Laya.Sprite3D, Type: EnemyType) {
//         if (Type == EnemyType.Blue_Enemy_Type) {
//             this.AddFllowSceneFiledMapUI(Target, null);
//         }
//     }
//     /**添加场景中的怪物图标 */
//     AddFiledMainSceneMap(Target: Laya.Sprite3D, Type: EnemyType) {
//         this.AddMainSceneFiledMapUI(Target, null);
//     }
//     /**添加怪物图标 */
//     AddMainSceneFiledMapUI(Target: Laya.Sprite3D, Obj: fairygui.GComponent) {
//         this.FiledSceneMapUI.set(Target, this.CreatorFiledMapUIInstance(Target, Obj));
//     }
//     /**添加怪物图标 */
//     AddFllowSceneFiledMapUI(Target: Laya.Sprite3D, Obj: fairygui.GComponent) {
//         this.FiledFpllowSceneMapUI.set(Target, this.CreatorFiledMapUIInstance(Target, Obj));
//     }
//     private AddMainSceneBlueMapUI(Target: Laya.Sprite3D, Obj: fairygui.GComponent) {
//         this.BlueSceneBeeMapUI.set(Target, this.CreatorBlueMapUIInstance(Obj));
//     }
//     private AddMainSceneRedMapUI(Target: Laya.Sprite3D, Obj: fairygui.GComponent) {
//         this.RedBSceneBeeMapUI.set(Target, this.CreatorRedPointMapUIInstance(Obj));
//     }
//     private AddBlueMapUI(Target: Laya.Sprite3D, Obj: fairygui.GComponent) {
//         this.BlueBeeMapUI.set(Target, this.CreatorBlueMapUIInstance(Obj));
//     }
//     private AddRedMapUI(Target: Laya.Sprite3D, Obj: fairygui.GComponent) {
//         this.RedBeeMapUI.set(Target, this.CreatorRedPointMapUIInstance(Obj));
//     }

//     /**--------- */
//     private SetFollowMapUI() {
//         if (this.m_IsPk) {
//             FightingPanelProxy.instance.ui.m_mapBtn.addChild(this.PlayerMapUI);
//             for (let entry of this.BlueBeeMapUI.entries()) {
//                 FightingPanelProxy.instance.ui.m_mapBtn.addChild(entry[1]);
//             }
//             for (let entry of this.RedBeeMapUI.entries()) {
//                 FightingPanelProxy.instance.ui.m_mapBtn.addChild(entry[1]);
//             }
//             for (let entry of this.FiledFpllowSceneMapUI.entries()) {
//                 FightingPanelProxy.instance.ui.m_mapBtn.addChild(entry[1]);
//             }
//         } else {
//             MainProxy.instance.ui.m_MainMapBtn.addChild(this.PlayerMapUI);
//             for (let entry of this.BlueBeeMapUI.entries()) {
//                 MainProxy.instance.ui.m_MainMapBtn.addChild(entry[1]);
//             }
//             for (let entry of this.RedBeeMapUI.entries()) {
//                 MainProxy.instance.ui.m_MainMapBtn.addChild(entry[1]);
//             }
//             for (let entry of this.FiledFpllowSceneMapUI.entries()) {
//                 MainProxy.instance.ui.m_MainMapBtn.addChild(entry[1]);
//             }
//         }
//     }

//     private SetMainSceneMapUI() {
//         this.PlayerSceneMapUI = this.CreatorPlayerMapUIInstance(null);
//         MapPanel.instance.ui.m_MapLoader.addChild(this.PlayerSceneMapUI);
//         this.CreatorUI();
//         for (let entry of this.BlueSceneBeeMapUI.entries()) {
//             MapPanel.instance.ui.m_MapLoader.addChild(entry[1]);
//         }
//         for (let entry of this.RedBSceneBeeMapUI.entries()) {
//             MapPanel.instance.ui.m_MapLoader.addChild(entry[1]);
//         }
//         for (let entry of this.FiledSceneMapUI.entries()) {
//             MapPanel.instance.ui.m_MapLoader.addChild(entry[1]);
//         }
//     }
//     CreatorUI() {

//         for (let entry of this.BlueSceneBeeMapUI.entries()) {
//             let UI = this.CreatorBlueMapUIInstance(null);
//             this.BlueSceneBeeMapUI.set(entry[0], UI);
//         }
//         for (let entry of this.RedBSceneBeeMapUI.entries()) {
//             let UI = this.CreatorRedPointMapUIInstance(null);
//             this.RedBSceneBeeMapUI.set(entry[0], UI);
//         }
//         for (let entry of this.FiledSceneMapUI.entries()) {
//             let UI = this.CreatorFiledMapUIInstance(entry[0], null);
//             this.FiledSceneMapUI.set(entry[0], UI);
//         }

//     }

//     /**创建 */
//     CreatorRedPointMapUIInstance(Obj: fairygui.GComponent): FGUI_RedPoint {
//         let TempUI = FGUI_RedPoint.createInstance();
//         if (Obj != null) {
//             Obj.addChild(TempUI);
//         }
//         return TempUI;
//     }

//     /**创建 */
//     CreatorBlueMapUIInstance(Obj: fairygui.GComponent): FGUI_GreenPoint {
//         let TempUI = FGUI_GreenPoint.createInstance();
//         if (Obj != null) {
//             Obj.addChild(TempUI);
//         }
//         return TempUI;
//     }

//     /**创建怪物图标 */
//     CreatorFiledMapUIInstance(Target: Laya.Sprite3D, Obj: fairygui.GComponent): FGUI_PlayerPoint {
//         let TempUI = FGUI_PlayerPoint.createInstance();
//         // let TempBee: HoneyBeesBase = Target.getComponent(HoneyBeesBase);
//         if (Target != null) {
//             switch (Target.name) {
//                 case "scorpion":
//                     TempUI.m_m_imageLoder.url = ComResUrl.MainFgui_url("scorpion_");
//                     break;
//                 case "spider":
//                     TempUI.m_m_imageLoder.url = ComResUrl.MainFgui_url("spider_");
//                     break;
//                 case "butterfly":
//                     TempUI.m_m_imageLoder.url = ComResUrl.MainFgui_url("butterfly_");
//                     break;
//                 default:
//                     TempUI.m_m_imageLoder.url = ComResUrl.MainFgui_url(Target.name);
//                     break;
//             }
//         }
//         if (Obj != null) {
//             Obj.addChild(TempUI);
//         }
//         return TempUI;
//     }

//     /**创建 */
//     CreatorPlayerMapUIInstance(Obj: fairygui.GComponent, ImgPath: string = ""): FGUI_PlayerPoint {
//         let TempUI = FGUI_PlayerPoint.createInstance();
//         if (ImgPath != "") {
//             TempUI.m_m_imageLoder.url = ComResUrl.MainFgui_url("");
//         }
//         if (Obj != null) {
//             Obj.addChild(TempUI);
//         }
//         return TempUI;
//     }


//     /**设置 雷达坐标 */
//     SetImagePos() {
//         let Pos = new Laya.Vector3();
//         if (this.FollowTarget != null && !this.FollowTarget.destroyed) {
//             CameraUtils.WorldToScreen2(this.FollowMapCamera, this.FollowTarget.transform.position, Pos);
//             if (this.PlayerMapUI != null) {
//                 let Ar = this.FollowTarget.transform.localRotationEulerY;
//                 if (Ar < 0) {
//                     Ar = Math.abs(Ar);
//                 } else {
//                     Ar = 360 - Ar;
//                 }
//                 this.PlayerMapUI.rotation = Ar;
//                 this.PlayerMapUI.setXY(Pos.x, Pos.y);
//             }
//         }

//         for (let entry of this.BlueBeeMapUI.entries()) {
//             Pos = new Laya.Vector3();
//             CameraUtils.WorldToScreen2(this.FollowMapCamera, entry[0].transform.position, Pos);
//             if (entry[1] != null) {
//                 entry[1].setXY(Pos.x, Pos.y);
//             }
//         }
//         for (let entry of this.FiledFpllowSceneMapUI.entries()) {
//             Pos = new Laya.Vector3();
//             CameraUtils.WorldToScreen2(this.FollowMapCamera, entry[0].transform.position, Pos);
//             if (entry[1] != null) {
//                 entry[1].setXY(Pos.x, Pos.y);
//             }
//         }
//         for (let entry of this.RedBeeMapUI.entries()) {
//             Pos = new Laya.Vector3();
//             CameraUtils.WorldToScreen2(this.FollowMapCamera, entry[0].transform.position, Pos);
//             if (entry[1] != null) {
//                 entry[1].setXY(Pos.x, Pos.y);
//             }
//         }
//     }
//     /**设置 雷达坐标 */
//     SetMainSceneMapUIPos() {

//         let Pos = new Laya.Vector3();
//         if (this.FollowTarget != null && !this.FollowTarget.destroyed) {
//             Pos = this.GetMapUIWorlPos(this.FollowTarget.transform.position);
//             if (this.PlayerSceneMapUI != null) {
//                 let Ar = this.FollowTarget.transform.localRotationEulerY;
//                 if (Ar < 0) {
//                     Ar = Math.abs(Ar);
//                 } else {
//                     Ar = 360 - Ar;
//                 }
//                 this.PlayerSceneMapUI.rotation = Ar;
//                 this.PlayerSceneMapUI.setXY(Pos.x, Pos.y);
//             }
//         }

//         for (let entry of this.BlueSceneBeeMapUI.entries()) {
//             Pos = new Laya.Vector3();
//             Pos = this.GetMapUIWorlPos(entry[0].transform.position);
//             if (entry[1] != null) {
//                 entry[1].setXY(Pos.x, Pos.y);
//             }
//         }
//         for (let entry of this.RedBSceneBeeMapUI.entries()) {
//             Pos = new Laya.Vector3();
//             Pos = this.GetMapUIWorlPos(entry[0].transform.position);
//             if (entry[1] != null) {
//                 entry[1].setXY(Pos.x, Pos.y);
//             }
//         }
//         for (let entry of this.FiledSceneMapUI.entries()) {
//             Pos = new Laya.Vector3();
//             Pos = this.GetMapUIWorlPos(entry[0].transform.position);
//             if (entry[1] != null) {
//                 entry[1].setXY(Pos.x, Pos.y);
//             }
//         }
//     }
//     GetMapUIWorlPos(TargetPos: Laya.Vector3): Laya.Vector3 {
//         let Pos = new Laya.Vector3();
//         switch (this.Layer) {
//             case Enum_SceneLayer.Room_Layer:
//                 CameraUtils.WorldToScreen2(this.RoomSceneCamera, TargetPos, Pos);
//                 break;
//             case Enum_SceneLayer.MainScene_Layer:
//                 CameraUtils.WorldToScreen2(this.MainSceneCamera, TargetPos, Pos);
//                 break;
//             case Enum_SceneLayer.Ememy_Layer:
//                 CameraUtils.WorldToScreen2(this.TempRoomSceneCamera, TargetPos, Pos);
//                 break;
//         }
//         return Pos;
//     }
//     CheckIsNull() {
//         let TempObjArray: Laya.Sprite3D[] = [];

//         if (this.FollowTarget == null || this.FollowTarget.destroyed) {
//             if (this.PlayerMapUI != null && !this.PlayerSceneMapUI.isDisposed) {
//                 this.PlayerMapUI.dispose();
//                 this.PlayerMapUI = null;
//             }
//             if (this.PlayerSceneMapUI != null && !this.PlayerSceneMapUI.isDisposed) {
//                 this.PlayerSceneMapUI.dispose();
//                 this.PlayerSceneMapUI = null;
//             }
//         }

//         /**-----蓝色-------------------------------------------------- */
//         for (let entry of this.BlueBeeMapUI.entries()) {
//             if (entry[0] == null || entry[0].destroyed) {
//                 if (entry[1] != null && !entry[1].isDisposed) {
//                     entry[1].dispose();
//                 }
//                 TempObjArray.push(entry[0]);
//             }
//         }
//         for (let i = 0; i < TempObjArray.length; i++) {
//             this.BlueBeeMapUI.delete(TempObjArray[i]);
//         }

//         for (let entry of this.FiledFpllowSceneMapUI.entries()) {
//             if (entry[0] == null || entry[0].destroyed) {
//                 if (entry[1] != null && !entry[1].isDisposed) {
//                     entry[1].dispose();
//                 }
//                 TempObjArray.push(entry[0]);
//             }
//         }
//         for (let i = 0; i < TempObjArray.length; i++) {
//             this.FiledFpllowSceneMapUI.delete(TempObjArray[i]);
//         }
//         /**-----红色-------------------------------------------------- */
//         TempObjArray = [];
//         for (let entry of this.RedBeeMapUI.entries()) {
//             if (entry[0] == null || entry[0].destroyed) {
//                 if (entry[1] != null && !entry[1].isDisposed) {
//                     entry[1].dispose();
//                 }
//                 TempObjArray.push(entry[0]);
//             }
//         }
//         for (let i = 0; i < TempObjArray.length; i++) {
//             this.RedBeeMapUI.delete(TempObjArray[i]);
//         }

//         /**-----场景蓝色-------------------------------------------------- */
//         TempObjArray = [];
//         for (let entry of this.BlueSceneBeeMapUI.entries()) {
//             if (entry[0] == null || entry[0].destroyed) {
//                 if (entry[1] != null && !entry[1].isDisposed) {
//                     entry[1].dispose();
//                 }
//                 TempObjArray.push(entry[0]);
//             }
//         }
//         for (let i = 0; i < TempObjArray.length; i++) {
//             this.BlueSceneBeeMapUI.delete(TempObjArray[i]);
//         }

//         /**-----场景红色-------------------------------------------------- */
//         TempObjArray = [];
//         for (let entry of this.RedBSceneBeeMapUI.entries()) {
//             if (entry[0] == null || entry[0].destroyed) {
//                 if (entry[1] != null && !entry[1].isDisposed) {
//                     entry[1].dispose();
//                 }
//                 TempObjArray.push(entry[0]);
//             }
//         }
//         for (let i = 0; i < TempObjArray.length; i++) {
//             this.RedBSceneBeeMapUI.delete(TempObjArray[i]);
//         }
//         /**-----场景怪物-------------------------------------------------- */
//         TempObjArray = [];
//         for (let entry of this.FiledSceneMapUI.entries()) {
//             if (entry[0] == null || entry[0].destroyed) {
//                 if (entry[1] != null && !entry[1].isDisposed) {
//                     entry[1].dispose();
//                 }
//                 TempObjArray.push(entry[0]);
//             }
//         }
//         for (let i = 0; i < TempObjArray.length; i++) {
//             this.FiledSceneMapUI.delete(TempObjArray[i]);
//         }
//     }

// }


